package com.song.eduservice.controller;

import com.song.commonutils.ResultObj;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.*;

/**
 * @author song
 * @data 2020/3/28
 */
@Api(description = "登陆")
@RestController
@RequestMapping("/eduservice/user")
public class EduLoginController {

    @PostMapping("login")
    public ResultObj login(){
        return ResultObj.LOGIN_SUCCESS.data("token","admin");
    }

    @GetMapping("info")
    public ResultObj info(){
        return ResultObj.ok().data("roles","[admin]").data("name","admin").data("avatar","https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif");
    }
}


